{template "content","header_page"}
<div class="bgbody" style="background: url(http://m.nsr.com.cn/resource/uploadfile/column_icon/21.jpg) no-repeat top center;">
    <div class="main">
        <div class="rightbox">
            <div class="tipsearch">
                <div class="topnav">
                    <ul>
                        <li class="pageLlist"><a href="/index.php?m=content&c=index&a=lists&catid=149" {if $catid == 157 || $catid == 158 || $catid == 159}class="onin" {/if}>北京校区</a><span>|</span>                            
                            <div class="submenu">
                                <a href="/index.php?m=content&c=index&a=lists&catid=157">少儿培训</a>
                                <a href="/index.php?m=content&c=index&a=lists&catid=158">成人培训</a>
                                <a href="/index.php?m=content&c=index&a=lists&catid=159">师资培训</a>                                    
                            </div>
                        </li>
                        <li class="pageLlist"><a href="/index.php?m=content&c=index&a=lists&catid=150" {if $catid == 160 || $catid == 161 || $catid == 162}class="onin" {/if}>深圳校区</a><span>|</span>                            
                            <div class="submenu">
                                <a href="/index.php?m=content&c=index&a=lists&catid=160">少儿培训</a>
                                <a href="/index.php?m=content&c=index&a=lists&catid=161">成人培训</a>
                                <a href="/index.php?m=content&c=index&a=lists&catid=162">师资培训</a>                                    
                            </div>
                        </li>
                        <li><a href="/index.php?m=content&c=index&a=lists&catid=151"  {if $catid == 151}class="onin"{/if}>师资力量</a><span>|</span></li>
                        <li class="pageLlist"><a href="/index.php?m=content&c=index&a=lists&catid=152" {if $catid == 152}class="onin"{/if}>学员风采</a><span>|</span>                            
                            <div class="submenu">
                                <a href="/index.php?m=content&c=index&a=lists&catid=152&label=3">少儿模特</a>
                                <a href="/index.php?m=content&c=index&a=lists&catid=152&label=1,2">成人模特</a>
                                <a href="/index.php?m=content&c=index&a=lists&catid=151">模特师资</a>                                    
                            </div>
                        </li>
                        
                        <li><a href="/index.php?m=content&c=index&a=lists&catid=153" {if $catid == 153}class="onin"{/if}>报名入口</a><span>|</span></li>
                        <li><a href="/index.php?m=content&c=index&a=lists&catid=154" {if $catid == 154}class="onin"{/if}>证书查询</a></li>
                    </ul>
                </div>
            </div>
            <div class="compete-box" id="compete-box">               
                <div class="white-wrap white-wrap1 fn_white_wrap" id="fn_white_wrap">
                    <div class="certificate-wrap">
                        <img class="ctfc-logo" src="{JS_PATH}nsrmodel/images/certificate/logo1.png" alt="nsr-logo">
                        <h2 class="ctfc-title">证书查询系统</h2>
                        <p class="row row1 bg1">
                            <label class="search-icon"></label>
                            <input class="ctfc-input fn_ctfc_input" type="text" name="number" id="number">
                            <span class="ctfc-input-txt fn_ctfc_input_txt">输入证书编码或身份证号码即可查询</span>
                        </p>
                        <p class="row row2">
                            <input class="ctfc-input-num bg1" type="text" name="code" id="code">
                            <?php echo form::checkcode('code_img')?>
                            <span class="ctfc-num-change" onclick="javascript:document.getElementById('code_img').src='<?php echo SITE_PROTOCOL.SITE_URL.WEB_PATH;?>api.php?op=checkcode&m=admin&c=index&a=checkcode&time='+Math.random();void(0);">点击更换验证码</span>
                        </p>
                        <p class="ctfc-warn-tip" id="ctfc-warn-tip" style="display:none;">未查询到此证书</p>
                        <a class="ctfc-btn-search" onclick="submit_number();">查&nbsp;&nbsp;&nbsp;询</a>
                    </div>
                </div>
            </div>
        </div>
    </div>
</div>
<script type="text/javascript">
    function submit_number () {
        var number = $('#number').val();
        var code = $('#code').val();
        if (!number) {
            $('#ctfc-warn-tip').html('请输入证书编码或身份证号码');
            $('#ctfc-warn-tip').show();
            return false;
        }
        if (!code) {
            $('#ctfc-warn-tip').html('请输入验证码');
            $('#ctfc-warn-tip').show();
            return false;
        }
        $.ajax({
            type: "POST",
            url: "index.php?m=content&c=rjson&a=submit_number",
            cache: false,
            dataType:"json",
            data: {number:number, code:code},
            success: function(result){
                if (result.status == 200) {
                    $('#compete-box').html(result.res);
                } else {
                    $('#ctfc-warn-tip').html(result.res);
                    $('#ctfc-warn-tip').show();
                } 
            },
            error: function(){
              alert('请求服务器失败');
            }
        });
    }
</script>
{template "content","footer"}